import { AccountModel } from '../model/account';
import ProxyInterface from '../proxy-interface';

class AccountModelProxy implements ProxyInterface<AccountModel> {
  public accountModel = new AccountModel();

  constructor (responseData) {
    let data = responseData.data || responseData;
    Object.assign<AccountModel, AccountModel>(this.accountModel, data)
  }

  getModel (): AccountModel {
    return this.accountModel;
  }
}

export default AccountModelProxy
